package demo7;

import org.springframework.context.annotation.AnnotationConfigApplicationContext;

import java.sql.SQLOutput;

public class Demo {
    public static void main(String[] args) {
        System.out.println("Spring容器开始初始化。。。。");
        AnnotationConfigApplicationContext contest=
                new AnnotationConfigApplicationContext("demo7");
        System.out.println("Spring容器初始化完毕");
        Person  person=contest.getBean(Person.class);

        System.out.println("正在关闭Spring容器。。");
        contest.close();
        System.out.println("Spring容器已关闭");
    }
}
